<?php
namespace Admin\Controller;
use Think\Controller;
class FindController extends Controller {
    public function findlist(){
        $findmodel=M('find');

        $find=$findmodel->order('id desc')->select();
        $this->find=$find;
        //调用视图层显示结果
        $this->display();
    }
    public function delfind($id)
    {
        $findmodel = M('find');
        if (false !== $findmodel->where("id=$id")->delete()) {
            $this->success('删除成功！');
        } else {
            $this->error('删除失败');
        }
    }
    public function detail($id){
        $findmodel=M('find');

        $find=$findmodel->where("id=$id")->select();
        $this->find=$find;
        //调用视图层显示结果
        $this->display();
    }
}